#pragma once

#include <QObject>
#include <qabstractitemmodel.h>

#include "ksongwebinfo.h"

class SongInfoModel  : public QAbstractListModel
{
	Q_OBJECT

public:
	SongInfoModel(QObject *parent);
	~SongInfoModel();

	virtual int
		rowCount(const QModelIndex& parent = QModelIndex())const override;

	virtual int
		columnCount(const QModelIndex& parent = QModelIndex())const override;

	virtual QVariant
		data(const QModelIndex& index, int role = Qt::DisplayRole)const override;

	
	KSongWebInfo* getSongInfo(const QModelIndex& index);
public slots:
	void setModelData(QVector<KSongWebInfo*> content);
private:
	QVector<KSongWebInfo*> m_songContent;
};
